package com.ti.srpglife.Screen;

import com.badlogic.gdx.Game;
import com.badlogic.gdx.Screen;
import com.badlogic.gdx.graphics.g2d.SpriteBatch;
import com.badlogic.gdx.scenes.scene2d.Stage;
import com.ti.srpglife.SRPGLIFEGame;

public abstract class AbstractScreen implements Screen 
{
	public SpriteBatch batch;
	public Stage stage;
	public SRPGLIFEGame game;
	
	public AbstractScreen(SRPGLIFEGame g) 
	{
		game = g;
		batch = new SpriteBatch();
		stage = new Stage();
	}

	public void render(float delta)
	{
		stage.act();
		stage.draw();
	}
	
	public void resize(int width, int height) 
	{
		stage.setViewport(width, height, false);
	}
	
	public void dispose()
	{
		stage.dispose();
	}
}
